#include <iostream>
#include "com_iiot_stream_tools_JNIRedis.h"
#include "redis_subscriber.h"
#include "global.h"
#include "logger.h"

using namespace std;

	
JNIEXPORT jstring JNICALL Java_com_iiot_stream_tools_JNIRedis_getRedisValue
         (JNIEnv * env, jobject, jstring jstr)
{
	const  char* pKey = NULL;
	string strValue;
	pKey = (env)->GetStringUTFChars(jstr,NULL);
	strValue = LookupMapValue(pKey);
	(env)->ReleaseStringUTFChars(jstr,pKey);
	return (env)->NewStringUTF(strValue.c_str());
}
